package cn.yh.register.hosp.repository;

import cn.yh.register.model.hosp.Schedule;
import org.springframework.data.mongodb.repository.MongoRepository;

import java.util.Date;
import java.util.List;

public interface ScheduleRepository extends MongoRepository<Schedule,String> {

    Schedule findByHoscodeAndHosScheduleId(String hoscode,String hosScheduleId);


    List<Schedule> findByHoscodeAndDepcodeAndWorkDate(String hoscode, String depcode, Date workDate);

    /**
     * 查询排班
     * @param hosScheduleId 医院排班主键
     * @return 排班信息
     */
    Schedule findByHosScheduleId(String hosScheduleId);
}
